package threaddemo;

public class MyThread extends Thread{
	private String name;

	public MyThread(String name) {
		super();
		
		
		this.name = name;
	}
	@Override
	public void run() {
	while(true){
		System.out.println(name);
		try {
			Thread.sleep(1000);
		} catch (InterruptedException e) {
			e.printStackTrace();
		}
	}
	}
}
